<!--title-->
<div class="mnav1">
    <div class="m_nav">
        <div class="nav_left">
            <em class="home_icon"><?=$this->sys_name?></em><span>&nbsp;&gt;&nbsp;</span><font><?=$this->title?></font>
        </div>
    </div>
</div>

<div class="content-table">
    <form action="/maozhua/mp-logs" name="form1" method="GET" style="float: left">
        日期：<input type="text" name="date_start" id="date_start" autocomplete="off" <?php if($this->date_start){echo "value='".$this->date_start."'";}?> style="width: 80px"> ~ <input type="text" name="date_end" id="date_end" autocomplete="off" <?php if($this->date_end){echo "value='".$this->date_end."'";}?> style="width: 80px">
        &nbsp;&nbsp;
        关键字：<input type="text" style="width: 100px;" name="keyword" <?php if($this->keyword){echo "value='".$this->keyword."'";}?> />
        &nbsp;&nbsp;&nbsp;
        <input type="submit" class="button" value="搜 索" style="width:60px"/>
        &nbsp;&nbsp;&nbsp;
        <input type="button" class="button-cancle" style="width:100px" value="清空条件" onclick="location.href='?';" />
    </form>
    <br />
    <table>
        <tr>
            <th>用户</th>
            <th>创建时间</th>
            <th>内容</th>
        </tr>
        <?php if($this->data):?>
            <?php foreach($this->data as $d):?>
                <tr>
                    <td><?php echo is_numeric($d['user_id'])?$d['user_name']:$d['user_id']?></td>
                    <td><?=$d['ctime']?></td>
                    <td><?=$d['content']?></td>
                </tr>
            <?php endforeach;?>
        <?php endif;?>
    </table>

    <br /><br /><div align="right"><?=$this->pagination?></div>
    <br /><br /><br />
    <br /><br />
    <script>
        var date = new Date();//获取当前时间
        date.setDate(date.getDate()-1);

        $(function() {
            $( "#date_start" ).datepicker({ dateFormat: 'yy-mm-dd'}).datepicker("setDate", "<?=$this->date_start?>");
        });

        $(function() {
            $( "#date_end" ).datepicker({ dateFormat: 'yy-mm-dd'}).datepicker("setDate", "<?=$this->date_end?>");
        });
    </script>